package com.ceba.test.webservice.entity;

/**
 * 龙脉key作为签名服务器
 * @author leeguang
 */
public class PrivateKeyConfLmKeyServer extends PrivateKeyConfAbstract {

    /**
     * 访问链接前缀
     * 比如：http://192.168.0.177:51235/alpha
     */
    private String httpUrl;

    /**
     * 获取证书的密码
     */
    private String password;

    /**
     * 证书的cn名字
     */
    private String cnName;

    public PrivateKeyConfLmKeyServer() {
        super();
    }

    public PrivateKeyConfLmKeyServer(String httpUrl, String password, String cnName) {
        super();
        this.httpUrl = httpUrl;
        this.password = password;
        this.cnName = cnName;
    }

    public PrivateKeyConfLmKeyServer(String httpUrl, String password, String cnName, String sigAlg, String publicKeyAlg) {
        super(sigAlg, publicKeyAlg);
        this.httpUrl = httpUrl;
        this.password = password;
        this.cnName = cnName;

        this.setType(3);
    }

    @Override
    public PrivateKeyType getPkType() {
        return PrivateKeyType.LM_KEY_SERVER;
    }

    public String getHttpUrl() {
        return httpUrl;
    }

    public void setHttpUrl(String httpUrl) {
        this.httpUrl = httpUrl;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getCnName() {
        return cnName;
    }

    public void setCnName(String cnName) {
        this.cnName = cnName;
    }
}
